<%@ page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8" %>
<%@ include file="/WEB-INF/jsp/public/common.jspf" %>

<head>
    <title>用户管理</title>
</head>

<div class="col-sm-9">
    <div class="row">
        <div class="col-lg-12">
            <div class="page-header">
                <h1>用户管理</h1>
            </div>
        </div>
    </div>

    <div class="row">
        <div class="col-lg-12">
            <div class="panel panel-default">
                <div class="panel-heading">
                    <div class="text-muted bootstrap-admin-box-title">用户列表</div>
                </div>
                <div class="bootstrap-admin-panel-content table-responsive">
                    <table class="table bootstrap-admin-table-with-actions">
                        <thead>
                        <tr>
                            <th>登录名</th>
                            <th>姓名</th>
                            <th>部门</th>
                            <th>用户组</th>
                            <th>操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        <s:iterator value="recordList">
                            <tr>
                                <td>${loginName}</td>
                                <td>${name}</td>
                                <td>${department}</td>
                                <td>${role.name}</td>
                                <td class="actions">
                                    <s:a cssClass="btn btn-sm btn-success" action="userManage_initPassword?id=%{id}"
                                         onclick="alert('确定要把密码重置为123456？')">
                                        <i class="glyphicon glyphicon-ok-sign"></i>
                                        重置密码
                                    </s:a>
                                    <s:a cssClass="btn btn-sm btn-danger" onclick="return confirm('确定要删除该用户么？')"
                                         action="userManage_delete?id=%{id}">
                                        <i class="glyphicon glyphicon-remove glyphicon-white"></i>
                                        删除
                                    </s:a>
                                    <s:a cssClass="btn btn-sm btn-info"
                                         action="userManage_editUI?id=%{id}">
                                        <i class="glyphicon glyphicon-edit glyphicon-white"></i>
                                        编辑
                                    </s:a>

                                </td>
                            </tr>
                        </s:iterator>
                        </tbody>
                    </table>

                    <!--pager start-->
                    <%@ include file="/WEB-INF/jsp/public/pageView.jspf" %>
                    <s:form action="userManage_list" cssstyle="display:none"></s:form>
                    <!--pager end-->

                </div>
            </div>
        </div>
    </div>

    <s:a action="userManage_addUI" cssClass="btn btn-sm btn-info"><i
            class="glyphicon glyphicon-plus glyphicon-white"></i> 添加用户</s:a>

</div>